home *** CD-ROM | disk | FTP | other *** search
/ Virtual Sex With Asia / Virtual Sex With Asia.iso / mac / Virtual Sex with Asia.Dxr / 00002_--• rearWindow.ls < prev    next >
Encoding:
Text File  |  1997-09-07  |  1.6 KB  |  83 lines

  1. on startMovie2
  2.   global gPrintObj
  3.   if the machineType <> 256 then
  4.     if factory("RearWindow") = 0 then
  5.       openXLib("REARWIN.XOB")
  6.     end if
  7.     initRearWindow()
  8.     fillWithSpecificColor(255)
  9.   end if
  10. end
  11.  
  12. on stopMovie2
  13. end
  14.  
  15. on initRearWindow
  16.   global rwObj
  17.   if objectp(rwObj) then
  18.     rwObj(mdispose)
  19.   end if
  20.   makeObjIfNeeded()
  21. end
  22.  
  23. on releaseRearWindow
  24.   global rwObj
  25.   if objectp(rwObj) then
  26.     rwObj(mdispose)
  27.   end if
  28. end
  29.  
  30. on UnCoverDesktop
  31.   global rwObj
  32.   if objectp(rwObj) then
  33.     rwObj(mdispose)
  34.   end if
  35.   unLoad()
  36. end
  37.  
  38. on makeObjIfNeeded
  39.   global rwObj
  40.   if not objectp(rwObj) then
  41.     set rwObj to RearWindow(mnew, "M")
  42.     if value(rwObj) < 0 then
  43.       alert("System error" && rwObj && "trying to create the RearWindow object in RAM (multiple-monitor config).")
  44.       stopMovie()
  45.       exit
  46.     end if
  47.     if the freeBlock < rwObj(mGetMemoryNeeded) then
  48.       if objectp(rwObj) then
  49.         rwObj(mdispose)
  50.         set rwObj to RearWindow(mnew, "S")
  51.       end if
  52.       if value(rwObj) < 0 then
  53.         alert("System error" && rwObj && "trying to create the RearWindow object in RAM (single-monitor config).")
  54.         stopMovie()
  55.         exit
  56.       end if
  57.     end if
  58.   end if
  59. end
  60.  
  61. on fillWithIndexColor
  62.   global rwObj
  63.   makeObjIfNeeded()
  64.   set patVar to 255
  65.   rwObj(mIndexColorToWindow, patVar)
  66. end
  67.  
  68. on fillWithSpecificColor whichColor
  69.   global rwObj
  70.   if the machineType <> 256 then
  71.     makeObjIfNeeded()
  72.     if whichColor = 0 then
  73.       rwObj(mPatToWindow, -1)
  74.     else
  75.       if whichColor = 255 then
  76.         rwObj(mPatToWindow, -5)
  77.       else
  78.         rwObj(mIndexColorToWindow, whichColor)
  79.       end if
  80.     end if
  81.   end if
  82. end
  83.